<template>
  <el-header class="topbar" height="50px">
    <el-row>
      <el-col :span="1">
        <img class="logo-img" src="/logo.jpg" />
      </el-col>
      <el-col :span="1" :offset="19">
        <a class="topbar-btn">用户</a>
      </el-col>
      <el-col :span="1">
        <a class="topbar-btn">用户</a>
      </el-col>
      <el-col :span="1">
        <el-dropdown style="width: 100%">
          <a class="topbar-btn">用户</a>
          <el-dropdown-menu slot="dropdown">
            <el-dropdown-item>查看</el-dropdown-item>
            <el-dropdown-item>新增</el-dropdown-item>
            <el-dropdown-item>删除</el-dropdown-item>
          </el-dropdown-menu>
        </el-dropdown>
      </el-col>
      <el-col :span="1" class="avatar-img-wrapper">
        <el-dropdown>
          <a class="topbar-btn" href="#"><img class="avatar-img" src="/avatar.jpg" /></a>
          <el-dropdown-menu slot="dropdown">
            <el-dropdown-item>查看</el-dropdown-item>
            <el-dropdown-item>新增</el-dropdown-item>
            <el-dropdown-item>删除</el-dropdown-item>
          </el-dropdown-menu>
        </el-dropdown>
      </el-col>
    </el-row>
  </el-header>
</template>

<script>
export default {
  name: "TopBar"
}
</script>

<style lang="stylus" scoped>
  .topbar
    background-color rgb(246, 246, 246)
    padding 0
    .logo-img
      max-width 70px
      overflow hidden
    .el-col
      text-align center
      height 50px
      background-color rgb(246, 246, 246)
    .topbar-btn 
      display block
      cursor pointer
      line-height 50px
      width 100%
      font-size 14px
      font-weight 300
      font-family "Microsoft Yahei"
      color #303133
    .topbar-btn:hover
      color rgb(102, 177, 255)
    .el-col:hover
      background-color rgb(236, 245, 255)
    .avatar-img
      border-radius 25px
      max-height 50px
      overflow hidden

    
</style>